# -*- coding: utf-8 -*-

GROUP_ID = -388138587  # new group id here
API_SEND_TEXT_MESSAGE = 'https://api.telegram.org/bot787244420:AAF5vto-krOSu4OCnHWI3e5IO-Wf_FSVFiQ/sendMessage'

CONSUMER_REDIS = 'redis://@172.20.3.138:6379/4'
CP_REDIS_URL = 'redis://@172.20.3.138:6379/0'
AGENT_CONSUMER_REDIS = 'redis://@172.20.3.138:6379/2'
DATA_CENTER_REDIS = 'redis://@192.168.70.129:6583/4'
MONGO_ADDR = 'mongodb://172.20.3.187:27017/'
ASYNC_LOG_REDIS = 'redis://172.20.3.138:6379/6'
GENERAL_REDIS = 'redis://@172.20.3.138:6379/7'

ES_CLUSTER_CLIENT_URLS = {
    'previous_cluster': {'http://localhost:9200': 1},
    'maestro': {'http://172.20.2.83:9200': 5},
}
KAFKA_SERVERS = ['172.20.3.233', '172.20.2.146', '172.20.1.215']
DC_KAFKA_SERVERS = ['192.168.70.129']

QK_CHANNEL_LIST_API = 'http://qiko69.com:9167/market/channel/channel_name/'
AGENT_CHANNEL_LIST_API = 'http://api.qt266.com/agent/api/bind_chn_list/'

AGENT_INDEX_MAP = {
    'dark2': 'dltgjm',
    'dark3': 'dltghj3',
    'dark4': 'dltgdark4',
    'tt': 'dltgtt',
    'zs': 'dltgzs'
}

FS_DIR = '/var/log/maestro/'

ES_KAFKA_GROUP_PREFIX = "prod_kafka_to_es"
BACK_UP_KAFKA_GROUP_ID = "prod_kafka_backup"
CONSUMER_TO_DC_KAFKA_GROUP_ID = "prod_kafka_to_dc"

DWC_INDEX = ['dark3', 'dark4']
CP_INDEX = ['loki', 'witch']
QK_INDEX = ['qk']
FRIDAY_INDEX = ['friday']
AGENT_INDEX = ['agent']
MF_PAY_INDEX = ['mf_pay']
OFFLINE_CALCULATION = ['offline_calculation']

PLATFORM_AMOUNT_ADJUST_RATE = 0.01

IS_PRODUCTION_ENV = True
INDEX_START_DATE = {
    'witch': '2019-02-12',
    'loki': '2018-11-01',
    'dark3': '2019-02-15',
    'dark4': '2019-08-01',
    'dark2': '2019-03-12',
    'zs': '2019-02-24',
    'tt': '2019-02-26'
}

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.mysql',
        'NAME': 'maestro',
        'USER': 'root',
        'PASSWORD': 'n0ra@wang',
        'HOST': '172.20.2.87',  # Or an IP Address that your DB is hosted on
        'PORT': '3306',
    }
}
SAFE_DOG_CONFIG = {
    "api_domain": "proxy.xyz115.com:8888",
    "app_key": "vpU4FWwsXTb3n6WA-ClN0WT1c4QLcQG68i2kvtRD",
    "app_secret": "z0i24xOv288PW9bD0L8V9uWxN2EQA7AFre9LFC4y",
    "use_https": False,
}